<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <title></title>
    <link rel="stylesheet" href="/stylesheets/index.css">
  </head>
  <body>
    <% include header.ejs %>
    <% if(comments.length>0){ %>
    <ul>
        <% for(comment of comments){ %>
          <li><%=comment.username.loginname%></li>
          <p><%=comment.text%></p>
        <% }%>
    </ul>
    <% } %>


    <%if(user){%>
      <form class="" action="/users/sendmsg" method="post">
        <textarea name="messagetext" rows="8" cols="80"></textarea>
        <img src="/users/commentvimg" alt=""><input type="text" name="vnum" placeholder="验证码" value="">
        <input type="submit" name="" value="提交">
      </form>

    <%}else{%>
      <h3>若要评论请先登陆</h3>
    <%}%>
  </body>
</html>
